package com.haixiaoke.saas.repository.mapper;


import com.haixiaoke.saas.repository.pojo.ApartmentLabel;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 公寓标签Mapper接口
 *
 * @author qixi
 * @date 2023-05-11
 */
public interface ApartmentLabelMapper {
    /**
     * 查询公寓标签
     *
     * @param labelId 公寓标签主键
     * @return 公寓标签
     */
    ApartmentLabel selectApartmentLabelByLabelId(Long labelId);

    /**
     * 查询公寓标签列表
     *
     * @param apartmentLabel 公寓标签
     * @return 公寓标签集合
     */
    List<ApartmentLabel> selectApartmentLabelList(ApartmentLabel apartmentLabel);

    /**
     * 新增公寓标签
     *
     * @param apartmentLabel 公寓标签
     * @return 结果
     */
    int insertApartmentLabel(ApartmentLabel apartmentLabel);

    /**
     * 修改公寓标签
     *
     * @param apartmentLabel 公寓标签
     * @return 结果
     */
    int updateApartmentLabel(ApartmentLabel apartmentLabel);

    /**
     * 删除公寓标签
     *
     * @param labelId 公寓标签主键
     * @return 结果
     */
    int deleteApartmentLabelByLabelId(Long labelId);

    /**
     * 批量删除公寓标签
     *
     * @param labelIds 需要删除的数据主键集合
     * @return 结果
     */
    int deleteApartmentLabelByLabelIds(Long[] labelIds);

    List<ApartmentLabel> selectApartmentLabelByOrgIdId(Long orgId);

    List<ApartmentLabel> selectApartmentLabelByLabelIdIn(List<Long> labelIds);

    int checkOrgIdLabelNameUnique(@Param("orgId") Long orgId, @Param("labelName") String labelName);
}
